import time
from io import BytesIO
import numpy as np

from selenium import webdriver
from selenium.webdriver.common.by import By
from PIL import Image


driver = webdriver.Chrome()


# 图片爬取
driver.get("https://blog.51cto.com/hanzhichao/3211285")
time.sleep(2)
html = driver.page_source.encode('utf-8')
print(html)

file = open("ax.html", 'wb+')
file.write(html)
file.close()

driver.quit()
